CC=gcc
CFLAGS=-g -c -Wall `pkg-config --cflags gtk+-2.0`
SOURCES=$(wildcard *.cpp)
LDFLAGS=-g `pkg-config --libs gtk+-2.0` -lstdc++
OBJECTS=$(SOURCES:.cpp=.o)
EXECUTABLE=hyper

.PHONY: all
all: $(SOURCES) $(EXECUTABLE)
	
$(EXECUTABLE): $(OBJECTS)
	$(CC) $(LDFLAGS) $(OBJECTS) -o $@

.cpp.o:
	$(CC) $(CFLAGS) $< -o $@



#for testing makefile syntax:)
.PHONY: tes
tes:
	@echo $(SOURCES)
	@echo === 
	@echo $(VCG_SOURCES)
	@echo === 
	@echo $(VCG_OBJECTS)


.PHONY: clean
clean:
	rm *.o $(EXECUTABLE)

